import arr from "@/utils/arr"

const CommonCode = {
    ON : '1',
    OFF : '2',

    textOfSwitch(input=null){
        let ar = {
            [CommonCode.ON] : '开',
            [CommonCode.OFF] : '关',
        };
        return input === null ? ar :  arr.get(ar, input, '')
    },


    SHOW : '1',
    HIDE : '2',

    textOfShowStatus(input=null){
        let ar = {
            [CommonCode.SHOW] : '显示',
            [CommonCode.HIDE] : '不显示',
        };
        return input === null ? ar :  arr.get(ar, input, '')
    },
}
export default CommonCode